package assignment.work01;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Work01 {
	public static void main(String[]args) {
		ApplicationContext app =  new ClassPathXmlApplicationContext("applicationContext-work01.xml");
		Work01Class1 work01Class11=app.getBean(Work01Class1.class);
		work01Class11.say();
		System.out.println(work01Class11);
		System.out.println(work01Class11.getClass());
		
		Work01Interface work01Class21=app.getBean(Work01Interface.class);
		work01Class21.say();
		System.out.println(work01Class21);
		System.out.println(work01Class21.getClass());
		
//		Work01Interface work01Class22=app.getBean(Work01Class2.class);
//		System.out.println(work01Class22);
//		System.out.println(work01Class22.getClass());
//		work01Class22.say();
	}
}
